$.ajaxSettings.beforeSend = function (xhr, request) {
    const user_token = window.localStorage.getItem('maoyan_token');
    if (!user_token) {
        return;
    }
    xhr.setRequestHeader('Authorization', `Bearer ${user_token}`);
}